Optimal. Leaf size=39 \[ \frac {a \cos (c+d x)}{d}+\frac {a \cos (c+d x)}{d (1-\sin (c+d x))}-a x \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.10, antiderivative size = 39, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 5, integrand size = 19, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.263, Rules used = {2708, 2746, 12, 2735, 2648} \[ \frac {a \cos (c+d x)}{d}+\frac {a \cos (c+d x)}{d (1-\sin (c+d x))}-a x \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 12
Rule 2648
Rule 2708
Rule 2735
Rule 2746
Rubi steps
\begin {align*} \int (a+a \sin (c+d x)) \tan ^2(c+d x) \, dx &=a^2 \int \frac {\sin ^2(c+d x)}{a-a \sin (c+d x)} \, dx\\ &=\frac {a \cos (c+d x)}{d}+a \int \frac {a \sin (c+d x)}{a-a \sin (c+d x)} \, dx\\ &=\frac {a \cos (c+d x)}{d}+a^2 \int \frac {\sin (c+d x)}{a-a \sin (c+d x)} \, dx\\ &=-a x+\frac {a \cos (c+d x)}{d}+a^2 \int \frac {1}{a-a \sin (c+d x)} \, dx\\ &=-a x+\frac {a \cos (c+d x)}{d}+\frac {a^2 \cos (c+d x)}{d (a-a \sin (c+d x))}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.04, size = 47, normalized size = 1.21 \[ \frac {a \cos (c+d x)}{d}-\frac {a \tan ^{-1}(\tan (c+d x))}{d}+\frac {a \tan (c+d x)}{d}+\frac {a \sec (c+d x)}{d} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [B] time = 0.44, size = 80, normalized size = 2.05 \[ -\frac {a d x - a \cos \left (d x + c\right )^{2} + {\left (a d x - 2 \, a\right )} \cos \left (d x + c\right ) - {\left (a d x - a \cos \left (d x + c\right ) + a\right )} \sin \left (d x + c\right ) - a}{d \cos \left (d x + c\right ) - d \sin \left (d x + c\right ) + d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [B] time = 0.17, size = 81, normalized size = 2.08 \[ -\frac {{\left (d x + c\right )} a + \frac {2 \, {\left (a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + 2 \, a\right )}}{\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} - \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 1}}{d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.30, size = 59, normalized size = 1.51 \[ \frac {a \left (\frac {\sin ^{4}\left (d x +c \right )}{\cos \left (d x +c \right )}+\left (2+\sin ^{2}\left (d x +c \right )\right ) \cos \left (d x +c \right )\right )+a \left (\tan \left (d x +c \right )-d x -c \right )}{d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.42, size = 39, normalized size = 1.00 \[ -\frac {{\left (d x + c - \tan \left (d x + c\right )\right )} a - a {\left (\frac {1}{\cos \left (d x + c\right )} + \cos \left (d x + c\right )\right )}}{d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 9.21, size = 99, normalized size = 2.54 \[ \frac {\left (a\,\left (d\,x-2\right )-a\,d\,x\right )\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2+\left (a\,d\,x-a\,\left (d\,x-2\right )\right )\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )+a\,\left (d\,x-4\right )-a\,d\,x}{d\,\left (\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )-1\right )\,\left ({\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2+1\right )}-a\,x \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F] time = 0.00, size = 0, normalized size = 0.00 \[ a \left (\int \sin ^{2}{\left (c + d x \right )} \sec ^{2}{\left (c + d x \right )}\, dx + \int \sin ^{3}{\left (c + d x \right )} \sec ^{2}{\left (c + d x \right )}\, dx\right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________